/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

/*
 * StartupCompanyManager2012CInfo.java
 *
 * Created on 29.11.2011, 14:29:54
 */
package startupcompanymanager2012;

import javax.swing.*;

/**
 *
 * @author Matthäus
 */
public class StartupCompanyManager2012CInfo extends javax.swing.JFrame {

    public static int spCount = 0, spFinished = 0, spFailed = 0, spLines = 0, spBugs = 0, spDays = 0;
    public static double spBonus = 0.00, spEarnings = 0.00, spLosses = 0.00;

    /** Creates new form StartupCompanyManager2012CInfo */
    public StartupCompanyManager2012CInfo() {
        initComponents();
        Core.calendarTimer.stop();
        listGames.setSelectedIndex(0);
        updateInfo();
    }

    /** Method which updates all of the labels etc. when called */
    public void updateInfo() {
        String devs = Integer.toString(Core.devs.size());
        String workst = Integer.toString(Core.office.getWorkstations());
        devList.setModel(new DefaultComboBoxModel(Core.devs.toArray()));
        compName.setText(Core.companyName);
        mainDevName.setText(Core.devs.get(0).getName());
        teamSize.setText(devs + "/" + workst);
        
        liveBudget.setText(Core.nfmt.format(Core.capital));
        listGames.setModel(new DefaultComboBoxModel(Core.games.toArray()));
        statusBar.setStringPainted(true);
        projectsBonus.setText(Core.nfmt.format(StartupCompanyManager2012CInfo.spBonus));
        projectsCount.setText(Integer.toString(StartupCompanyManager2012CInfo.spCount));
        projectsDays.setText(Integer.toString(StartupCompanyManager2012CInfo.spDays));
        projectsEarnings.setText(Core.nfmt.format(StartupCompanyManager2012CInfo.spEarnings));
        projectsFailed.setText(Integer.toString(StartupCompanyManager2012CInfo.spFailed));
        projectsFinished.setText(Integer.toString(StartupCompanyManager2012CInfo.spFinished));
        projectsLines.setText(Integer.toString(StartupCompanyManager2012CInfo.spLines));
        projectsMoneyLost.setText(Core.nfmt.format(StartupCompanyManager2012CInfo.spLosses));
        projectsTotalBugs.setText(Integer.toString(StartupCompanyManager2012CInfo.spBugs));

    }

    /** This method is called from within the constructor to
     * initialize the form.
     * WARNING: Do NOT modify this code. The content of this method is
     * always regenerated by the Form Editor.
     */
    @SuppressWarnings("unchecked")
    // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
    private void initComponents() {

        tabInfoPane = new javax.swing.JTabbedPane();
        panelGeneral = new javax.swing.JPanel();
        labelCompanyName = new javax.swing.JLabel();
        labelMainDev = new javax.swing.JLabel();
        mainDevName = new javax.swing.JLabel();
        labelDevTeam = new javax.swing.JLabel();
        devListScroll = new javax.swing.JScrollPane();
        devList = new javax.swing.JList();
        lableNumGames = new javax.swing.JLabel();
        numGames = new javax.swing.JLabel();
        labelDaysWorked = new javax.swing.JLabel();
        daysWorked = new javax.swing.JLabel();
        labelTeamSize = new javax.swing.JLabel();
        teamSize = new javax.swing.JLabel();
        labelTotalExp = new javax.swing.JLabel();
        totalExp = new javax.swing.JLabel();
        liveBudget = new javax.swing.JLabel();
        labelBudget = new javax.swing.JLabel();
        compName = new javax.swing.JLabel();
        panelGames = new javax.swing.JPanel();
        jScrollPane1 = new javax.swing.JScrollPane();
        listGames = new javax.swing.JList();
        labelStatus = new javax.swing.JLabel();
        statusBar = new javax.swing.JProgressBar(0,100);
        jPanel1 = new javax.swing.JPanel();
        gameScore = new javax.swing.JLabel();
        gameBugs = new javax.swing.JLabel();
        gamePrice = new javax.swing.JLabel();
        labelBugs = new javax.swing.JLabel();
        labelScore = new javax.swing.JLabel();
        labelPrice = new javax.swing.JLabel();
        labelLines = new javax.swing.JLabel();
        gameLines = new javax.swing.JLabel();
        jPanel2 = new javax.swing.JPanel();
        gameLanguage = new javax.swing.JLabel();
        labelPlatform = new javax.swing.JLabel();
        labelLanguage = new javax.swing.JLabel();
        labelFocus = new javax.swing.JLabel();
        lableType = new javax.swing.JLabel();
        labelGenre = new javax.swing.JLabel();
        gameGenre = new javax.swing.JLabel();
        gamePlatform = new javax.swing.JLabel();
        gameType = new javax.swing.JLabel();
        gameFocus = new javax.swing.JLabel();
        gameName = new javax.swing.JLabel();
        labelGameName = new javax.swing.JLabel();
        labelGameDev = new javax.swing.JLabel();
        gameDev = new javax.swing.JLabel();
        panelFinancial = new javax.swing.JPanel();
        panelSideProject = new javax.swing.JPanel();
        labelProjectsCount = new javax.swing.JLabel();
        labelProjectsFinished = new javax.swing.JLabel();
        labelProjectsFailed = new javax.swing.JLabel();
        labelProjectEarnings = new javax.swing.JLabel();
        labelProjectBonus = new javax.swing.JLabel();
        labelProjectMoneyLost = new javax.swing.JLabel();
        labelProjectsLines = new javax.swing.JLabel();
        labelProjectsBugs = new javax.swing.JLabel();
        projectsCount = new javax.swing.JLabel();
        projectsFinished = new javax.swing.JLabel();
        projectsFailed = new javax.swing.JLabel();
        projectsEarnings = new javax.swing.JLabel();
        projectsBonus = new javax.swing.JLabel();
        projectsMoneyLost = new javax.swing.JLabel();
        projectsLines = new javax.swing.JLabel();
        projectsTotalBugs = new javax.swing.JLabel();
        labelProjectsDays = new javax.swing.JLabel();
        projectsDays = new javax.swing.JLabel();
        closeButton = new javax.swing.JButton();

        setDefaultCloseOperation(javax.swing.WindowConstants.DISPOSE_ON_CLOSE);
        org.jdesktop.application.ResourceMap resourceMap = org.jdesktop.application.Application.getInstance(startupcompanymanager2012.StartupCompanyManager2012App.class).getContext().getResourceMap(StartupCompanyManager2012CInfo.class);
        setTitle(resourceMap.getString("Form.title")); // NOI18N
        setBackground(resourceMap.getColor("Form.background")); // NOI18N
        setName("Form"); // NOI18N
        setResizable(false);
        addWindowListener(new java.awt.event.WindowAdapter() {
            public void windowClosed(java.awt.event.WindowEvent evt) {
                frameDisposed(evt);
            }
        });

        tabInfoPane.setBackground(resourceMap.getColor("tabInfoPane.background")); // NOI18N
        tabInfoPane.setForeground(resourceMap.getColor("tabInfoPane.foreground")); // NOI18N
        tabInfoPane.setName("tabInfoPane"); // NOI18N

        panelGeneral.setBackground(resourceMap.getColor("panelGeneral.background")); // NOI18N
        panelGeneral.setName("panelGeneral"); // NOI18N

        labelCompanyName.setText(resourceMap.getString("labelCompanyName.text")); // NOI18N
        labelCompanyName.setName("labelCompanyName"); // NOI18N

        labelMainDev.setText(resourceMap.getString("labelMainDev.text")); // NOI18N
        labelMainDev.setName("labelMainDev"); // NOI18N

        mainDevName.setText(resourceMap.getString("mainDevName.text")); // NOI18N
        mainDevName.setName("mainDevName"); // NOI18N

        labelDevTeam.setText(resourceMap.getString("labelDevTeam.text")); // NOI18N
        labelDevTeam.setName("labelDevTeam"); // NOI18N

        devListScroll.setName("devListScroll"); // NOI18N

        devList.setModel(new javax.swing.AbstractListModel() {
            String[] strings = { "Item 1", "Item 2", "Item 3", "Item 4", "Item 5" };
            public int getSize() { return strings.length; }
            public Object getElementAt(int i) { return strings[i]; }
        });
        devList.setName("devList"); // NOI18N
        devList.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mousePressed(java.awt.event.MouseEvent evt) {
                viewDevInfo(evt);
            }
        });
        devListScroll.setViewportView(devList);

        lableNumGames.setText(resourceMap.getString("lableNumGames.text")); // NOI18N
        lableNumGames.setName("lableNumGames"); // NOI18N

        numGames.setText(resourceMap.getString("numGames.text")); // NOI18N
        numGames.setName("numGames"); // NOI18N

        labelDaysWorked.setText(resourceMap.getString("labelDaysWorked.text")); // NOI18N
        labelDaysWorked.setName("labelDaysWorked"); // NOI18N

        daysWorked.setText(resourceMap.getString("daysWorked.text")); // NOI18N
        daysWorked.setName("daysWorked"); // NOI18N

        labelTeamSize.setText(resourceMap.getString("labelTeamSize.text")); // NOI18N
        labelTeamSize.setName("labelTeamSize"); // NOI18N

        teamSize.setText(resourceMap.getString("teamSize.text")); // NOI18N
        teamSize.setName("teamSize"); // NOI18N

        labelTotalExp.setText(resourceMap.getString("labelTotalExp.text")); // NOI18N
        labelTotalExp.setName("labelTotalExp"); // NOI18N

        totalExp.setText(resourceMap.getString("totalExp.text")); // NOI18N
        totalExp.setName("totalExp"); // NOI18N

        liveBudget.setText(resourceMap.getString("liveBudget.text")); // NOI18N
        liveBudget.setName("liveBudget"); // NOI18N

        labelBudget.setText(resourceMap.getString("labelBudget.text")); // NOI18N
        labelBudget.setName("labelBudget"); // NOI18N

        compName.setText(resourceMap.getString("compName.text")); // NOI18N
        compName.setName("compName"); // NOI18N

        javax.swing.GroupLayout panelGeneralLayout = new javax.swing.GroupLayout(panelGeneral);
        panelGeneral.setLayout(panelGeneralLayout);
        panelGeneralLayout.setHorizontalGroup(
            panelGeneralLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(panelGeneralLayout.createSequentialGroup()
                .addContainerGap()
                .addGroup(panelGeneralLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addGroup(panelGeneralLayout.createSequentialGroup()
                        .addComponent(labelCompanyName)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(compName)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, 258, Short.MAX_VALUE)
                        .addComponent(labelBudget)
                        .addGap(29, 29, 29)
                        .addComponent(liveBudget))
                    .addGroup(panelGeneralLayout.createSequentialGroup()
                        .addComponent(labelMainDev)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(mainDevName))
                    .addGroup(panelGeneralLayout.createSequentialGroup()
                        .addComponent(devListScroll, javax.swing.GroupLayout.PREFERRED_SIZE, 105, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                        .addGroup(panelGeneralLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                            .addGroup(panelGeneralLayout.createSequentialGroup()
                                .addComponent(labelTeamSize)
                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                .addComponent(teamSize))
                            .addGroup(panelGeneralLayout.createSequentialGroup()
                                .addComponent(lableNumGames)
                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                .addComponent(numGames))
                            .addGroup(panelGeneralLayout.createSequentialGroup()
                                .addComponent(labelDaysWorked)
                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                .addComponent(daysWorked))
                            .addGroup(panelGeneralLayout.createSequentialGroup()
                                .addComponent(labelTotalExp)
                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                .addComponent(totalExp))))
                    .addComponent(labelDevTeam))
                .addContainerGap())
        );
        panelGeneralLayout.setVerticalGroup(
            panelGeneralLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(panelGeneralLayout.createSequentialGroup()
                .addContainerGap()
                .addGroup(panelGeneralLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(labelCompanyName)
                    .addComponent(liveBudget)
                    .addComponent(labelBudget)
                    .addComponent(compName))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                .addGroup(panelGeneralLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(labelMainDev)
                    .addComponent(mainDevName))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                .addComponent(labelDevTeam)
                .addGap(9, 9, 9)
                .addGroup(panelGeneralLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addGroup(panelGeneralLayout.createSequentialGroup()
                        .addGap(5, 5, 5)
                        .addGroup(panelGeneralLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                            .addComponent(labelTeamSize)
                            .addComponent(teamSize))
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addGroup(panelGeneralLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                            .addComponent(labelDaysWorked)
                            .addComponent(daysWorked))
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addGroup(panelGeneralLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                            .addComponent(lableNumGames)
                            .addComponent(numGames))
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addGroup(panelGeneralLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                            .addComponent(labelTotalExp)
                            .addComponent(totalExp)))
                    .addComponent(devListScroll, javax.swing.GroupLayout.PREFERRED_SIZE, 125, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addContainerGap(45, Short.MAX_VALUE))
        );

        tabInfoPane.addTab(resourceMap.getString("panelGeneral.TabConstraints.tabTitle"), panelGeneral); // NOI18N

        panelGames.setBackground(resourceMap.getColor("panelGames.background")); // NOI18N
        panelGames.setName("panelGames"); // NOI18N

        jScrollPane1.setName("jScrollPane1"); // NOI18N

        listGames.setModel(new javax.swing.AbstractListModel() {
            String[] strings = { "Item 1", "Item 2", "Item 3", "Item 4", "Item 5" };
            public int getSize() { return strings.length; }
            public Object getElementAt(int i) { return strings[i]; }
        });
        listGames.setName("listGames"); // NOI18N
        listGames.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseClicked(java.awt.event.MouseEvent evt) {
                showInfo(evt);
            }
        });
        jScrollPane1.setViewportView(listGames);

        labelStatus.setText(resourceMap.getString("labelStatus.text")); // NOI18N
        labelStatus.setName("labelStatus"); // NOI18N

        statusBar.setName("statusBar"); // NOI18N

        jPanel1.setMaximumSize(new java.awt.Dimension(125, 132));
        jPanel1.setName("jPanel1"); // NOI18N
        jPanel1.setPreferredSize(new java.awt.Dimension(119, 132));

        gameScore.setText(resourceMap.getString("gameScore.text")); // NOI18N
        gameScore.setName("gameScore"); // NOI18N

        gameBugs.setText(resourceMap.getString("gameBugs.text")); // NOI18N
        gameBugs.setName("gameBugs"); // NOI18N

        gamePrice.setText(resourceMap.getString("gamePrice.text")); // NOI18N
        gamePrice.setName("gamePrice"); // NOI18N

        labelBugs.setText(resourceMap.getString("labelBugs.text")); // NOI18N
        labelBugs.setName("labelBugs"); // NOI18N

        labelScore.setText(resourceMap.getString("labelScore.text")); // NOI18N
        labelScore.setName("labelScore"); // NOI18N

        labelPrice.setText(resourceMap.getString("labelPrice.text")); // NOI18N
        labelPrice.setName("labelPrice"); // NOI18N

        labelLines.setText(resourceMap.getString("labelLines.text")); // NOI18N
        labelLines.setName("labelLines"); // NOI18N

        gameLines.setText(resourceMap.getString("gameLines.text")); // NOI18N
        gameLines.setName("gameLines"); // NOI18N

        javax.swing.GroupLayout jPanel1Layout = new javax.swing.GroupLayout(jPanel1);
        jPanel1.setLayout(jPanel1Layout);
        jPanel1Layout.setHorizontalGroup(
            jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanel1Layout.createSequentialGroup()
                .addContainerGap()
                .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addGroup(jPanel1Layout.createSequentialGroup()
                        .addComponent(labelScore)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(gameScore, javax.swing.GroupLayout.DEFAULT_SIZE, 82, Short.MAX_VALUE))
                    .addGroup(jPanel1Layout.createSequentialGroup()
                        .addComponent(labelPrice)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(gamePrice))
                    .addGroup(jPanel1Layout.createSequentialGroup()
                        .addComponent(labelLines)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(gameLines))
                    .addGroup(jPanel1Layout.createSequentialGroup()
                        .addComponent(labelBugs)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(gameBugs)))
                .addContainerGap(22, javax.swing.GroupLayout.PREFERRED_SIZE))
        );
        jPanel1Layout.setVerticalGroup(
            jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanel1Layout.createSequentialGroup()
                .addContainerGap()
                .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(labelPrice)
                    .addComponent(gamePrice))
                .addGap(18, 18, 18)
                .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(labelScore)
                    .addComponent(gameScore, javax.swing.GroupLayout.PREFERRED_SIZE, 14, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addGap(18, 18, 18)
                .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(labelLines)
                    .addComponent(gameLines))
                .addGap(18, 18, 18)
                .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(labelBugs)
                    .addComponent(gameBugs))
                .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
        );

        jPanel2.setName("jPanel2"); // NOI18N

        gameLanguage.setText(resourceMap.getString("gameLanguage.text")); // NOI18N
        gameLanguage.setName("gameLanguage"); // NOI18N

        labelPlatform.setText(resourceMap.getString("labelPlatform.text")); // NOI18N
        labelPlatform.setName("labelPlatform"); // NOI18N

        labelLanguage.setText(resourceMap.getString("labelLanguage.text")); // NOI18N
        labelLanguage.setName("labelLanguage"); // NOI18N

        labelFocus.setText(resourceMap.getString("labelFocus.text")); // NOI18N
        labelFocus.setName("labelFocus"); // NOI18N

        lableType.setText(resourceMap.getString("lableType.text")); // NOI18N
        lableType.setName("lableType"); // NOI18N

        labelGenre.setText(resourceMap.getString("labelGenre.text")); // NOI18N
        labelGenre.setName("labelGenre"); // NOI18N

        gameGenre.setText(resourceMap.getString("gameGenre.text")); // NOI18N
        gameGenre.setName("gameGenre"); // NOI18N

        gamePlatform.setText(resourceMap.getString("gamePlatform.text")); // NOI18N
        gamePlatform.setName("gamePlatform"); // NOI18N

        gameType.setText(resourceMap.getString("gameType.text")); // NOI18N
        gameType.setName("gameType"); // NOI18N

        gameFocus.setText(resourceMap.getString("gameFocus.text")); // NOI18N
        gameFocus.setName("gameFocus"); // NOI18N

        javax.swing.GroupLayout jPanel2Layout = new javax.swing.GroupLayout(jPanel2);
        jPanel2.setLayout(jPanel2Layout);
        jPanel2Layout.setHorizontalGroup(
            jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanel2Layout.createSequentialGroup()
                .addContainerGap()
                .addGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addGroup(jPanel2Layout.createSequentialGroup()
                        .addComponent(labelPlatform)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(gamePlatform))
                    .addGroup(jPanel2Layout.createSequentialGroup()
                        .addComponent(labelGenre)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(gameGenre))
                    .addGroup(jPanel2Layout.createSequentialGroup()
                        .addComponent(lableType)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(gameType))
                    .addGroup(jPanel2Layout.createSequentialGroup()
                        .addComponent(labelFocus)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(gameFocus))
                    .addGroup(jPanel2Layout.createSequentialGroup()
                        .addComponent(labelLanguage)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(gameLanguage)))
                .addContainerGap(48, Short.MAX_VALUE))
        );
        jPanel2Layout.setVerticalGroup(
            jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanel2Layout.createSequentialGroup()
                .addContainerGap()
                .addGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(labelGenre)
                    .addComponent(gameGenre))
                .addGap(18, 18, 18)
                .addGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(lableType)
                    .addComponent(gameType))
                .addGap(18, 18, 18)
                .addGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(labelFocus)
                    .addComponent(gameFocus))
                .addGap(18, 18, 18)
                .addGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(labelLanguage, javax.swing.GroupLayout.PREFERRED_SIZE, 14, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(gameLanguage))
                .addGap(18, 18, 18)
                .addGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(labelPlatform)
                    .addComponent(gamePlatform))
                .addContainerGap())
        );

        gameName.setText(resourceMap.getString("gameName.text")); // NOI18N
        gameName.setName("gameName"); // NOI18N

        labelGameName.setText(resourceMap.getString("labelGameName.text")); // NOI18N
        labelGameName.setName("labelGameName"); // NOI18N

        labelGameDev.setText(resourceMap.getString("labelGameDev.text")); // NOI18N
        labelGameDev.setName("labelGameDev"); // NOI18N

        gameDev.setText(resourceMap.getString("gameDev.text")); // NOI18N
        gameDev.setName("gameDev"); // NOI18N

        javax.swing.GroupLayout panelGamesLayout = new javax.swing.GroupLayout(panelGames);
        panelGames.setLayout(panelGamesLayout);
        panelGamesLayout.setHorizontalGroup(
            panelGamesLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(panelGamesLayout.createSequentialGroup()
                .addContainerGap()
                .addComponent(jScrollPane1, javax.swing.GroupLayout.PREFERRED_SIZE, 136, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                .addGroup(panelGamesLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addGroup(panelGamesLayout.createSequentialGroup()
                        .addComponent(labelGameDev)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                        .addComponent(gameDev))
                    .addGroup(panelGamesLayout.createSequentialGroup()
                        .addComponent(labelGameName)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(gameName))
                    .addGroup(panelGamesLayout.createSequentialGroup()
                        .addGroup(panelGamesLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                            .addComponent(labelStatus)
                            .addComponent(jPanel1, javax.swing.GroupLayout.DEFAULT_SIZE, 151, Short.MAX_VALUE))
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(jPanel2, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                    .addComponent(statusBar, javax.swing.GroupLayout.DEFAULT_SIZE, 280, Short.MAX_VALUE))
                .addContainerGap())
        );
        panelGamesLayout.setVerticalGroup(
            panelGamesLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(panelGamesLayout.createSequentialGroup()
                .addContainerGap()
                .addGroup(panelGamesLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING, false)
                    .addComponent(jScrollPane1, javax.swing.GroupLayout.Alignment.LEADING)
                    .addGroup(javax.swing.GroupLayout.Alignment.LEADING, panelGamesLayout.createSequentialGroup()
                        .addGroup(panelGamesLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING)
                            .addComponent(gameName)
                            .addComponent(labelGameName))
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                        .addGroup(panelGamesLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false)
                            .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, panelGamesLayout.createSequentialGroup()
                                .addComponent(jPanel1, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                                .addComponent(labelStatus))
                            .addComponent(jPanel2, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(statusBar, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addGroup(panelGamesLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                            .addComponent(labelGameDev)
                            .addComponent(gameDev))))
                .addGap(14, 14, 14))
        );

        tabInfoPane.addTab(resourceMap.getString("panelGames.TabConstraints.tabTitle"), panelGames); // NOI18N

        panelFinancial.setBackground(resourceMap.getColor("panelFinancial.background")); // NOI18N
        panelFinancial.setName("panelFinancial"); // NOI18N

        javax.swing.GroupLayout panelFinancialLayout = new javax.swing.GroupLayout(panelFinancial);
        panelFinancial.setLayout(panelFinancialLayout);
        panelFinancialLayout.setHorizontalGroup(
            panelFinancialLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGap(0, 446, Short.MAX_VALUE)
        );
        panelFinancialLayout.setVerticalGroup(
            panelFinancialLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGap(0, 254, Short.MAX_VALUE)
        );

        tabInfoPane.addTab(resourceMap.getString("panelFinancial.TabConstraints.tabTitle"), panelFinancial); // NOI18N

        panelSideProject.setBackground(resourceMap.getColor("panelSideProject.background")); // NOI18N
        panelSideProject.setName("panelSideProject"); // NOI18N

        labelProjectsCount.setText(resourceMap.getString("labelProjectsCount.text")); // NOI18N
        labelProjectsCount.setName("labelProjectsCount"); // NOI18N

        labelProjectsFinished.setText(resourceMap.getString("labelProjectsFinished.text")); // NOI18N
        labelProjectsFinished.setName("labelProjectsFinished"); // NOI18N

        labelProjectsFailed.setText(resourceMap.getString("labelProjectsFailed.text")); // NOI18N
        labelProjectsFailed.setName("labelProjectsFailed"); // NOI18N

        labelProjectEarnings.setText(resourceMap.getString("labelProjectEarnings.text")); // NOI18N
        labelProjectEarnings.setName("labelProjectEarnings"); // NOI18N

        labelProjectBonus.setText(resourceMap.getString("labelProjectBonus.text")); // NOI18N
        labelProjectBonus.setName("labelProjectBonus"); // NOI18N

        labelProjectMoneyLost.setText(resourceMap.getString("labelProjectMoneyLost.text")); // NOI18N
        labelProjectMoneyLost.setName("labelProjectMoneyLost"); // NOI18N

        labelProjectsLines.setText(resourceMap.getString("labelProjectsLines.text")); // NOI18N
        labelProjectsLines.setName("labelProjectsLines"); // NOI18N

        labelProjectsBugs.setText(resourceMap.getString("labelProjectsBugs.text")); // NOI18N
        labelProjectsBugs.setName("labelProjectsBugs"); // NOI18N

        projectsCount.setText(resourceMap.getString("projectsCount.text")); // NOI18N
        projectsCount.setName("projectsCount"); // NOI18N

        projectsFinished.setText(resourceMap.getString("projectsFinished.text")); // NOI18N
        projectsFinished.setName("projectsFinished"); // NOI18N

        projectsFailed.setText(resourceMap.getString("projectsFailed.text")); // NOI18N
        projectsFailed.setName("projectsFailed"); // NOI18N

        projectsEarnings.setText(resourceMap.getString("projectsEarnings.text")); // NOI18N
        projectsEarnings.setName("projectsEarnings"); // NOI18N

        projectsBonus.setText(resourceMap.getString("projectsBonus.text")); // NOI18N
        projectsBonus.setName("projectsBonus"); // NOI18N

        projectsMoneyLost.setText(resourceMap.getString("projectsMoneyLost.text")); // NOI18N
        projectsMoneyLost.setName("projectsMoneyLost"); // NOI18N

        projectsLines.setText(resourceMap.getString("projectsLines.text")); // NOI18N
        projectsLines.setName("projectsLines"); // NOI18N

        projectsTotalBugs.setText(resourceMap.getString("projectsTotalBugs.text")); // NOI18N
        projectsTotalBugs.setName("projectsTotalBugs"); // NOI18N

        labelProjectsDays.setText(resourceMap.getString("labelProjectsDays.text")); // NOI18N
        labelProjectsDays.setName("labelProjectsDays"); // NOI18N

        projectsDays.setText(resourceMap.getString("projectsDays.text")); // NOI18N
        projectsDays.setName("projectsDays"); // NOI18N

        javax.swing.GroupLayout panelSideProjectLayout = new javax.swing.GroupLayout(panelSideProject);
        panelSideProject.setLayout(panelSideProjectLayout);
        panelSideProjectLayout.setHorizontalGroup(
            panelSideProjectLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(panelSideProjectLayout.createSequentialGroup()
                .addContainerGap()
                .addGroup(panelSideProjectLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addGroup(panelSideProjectLayout.createSequentialGroup()
                        .addComponent(labelProjectsFinished)
                        .addGap(4, 4, 4)
                        .addComponent(projectsFinished)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                        .addComponent(labelProjectsFailed)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(projectsFailed))
                    .addGroup(panelSideProjectLayout.createSequentialGroup()
                        .addComponent(labelProjectBonus)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(projectsBonus))
                    .addGroup(panelSideProjectLayout.createSequentialGroup()
                        .addComponent(labelProjectsCount)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(projectsCount))
                    .addGroup(panelSideProjectLayout.createSequentialGroup()
                        .addComponent(labelProjectEarnings)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(projectsEarnings))
                    .addGroup(panelSideProjectLayout.createSequentialGroup()
                        .addComponent(labelProjectMoneyLost)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(projectsMoneyLost))
                    .addGroup(panelSideProjectLayout.createSequentialGroup()
                        .addComponent(labelProjectsBugs)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(projectsTotalBugs))
                    .addGroup(panelSideProjectLayout.createSequentialGroup()
                        .addComponent(labelProjectsLines)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(projectsLines))
                    .addGroup(panelSideProjectLayout.createSequentialGroup()
                        .addComponent(labelProjectsDays)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(projectsDays)))
                .addContainerGap(325, Short.MAX_VALUE))
        );
        panelSideProjectLayout.setVerticalGroup(
            panelSideProjectLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(panelSideProjectLayout.createSequentialGroup()
                .addContainerGap()
                .addGroup(panelSideProjectLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(labelProjectsCount)
                    .addComponent(projectsCount))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                .addGroup(panelSideProjectLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(labelProjectsFinished)
                    .addComponent(labelProjectsFailed)
                    .addComponent(projectsFinished)
                    .addComponent(projectsFailed))
                .addGap(30, 30, 30)
                .addGroup(panelSideProjectLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(labelProjectEarnings)
                    .addComponent(projectsEarnings))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addGroup(panelSideProjectLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(labelProjectBonus)
                    .addComponent(projectsBonus))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addGroup(panelSideProjectLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(labelProjectMoneyLost)
                    .addComponent(projectsMoneyLost))
                .addGap(18, 18, 18)
                .addGroup(panelSideProjectLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(labelProjectsLines)
                    .addComponent(projectsLines))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addGroup(panelSideProjectLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(labelProjectsBugs)
                    .addComponent(projectsTotalBugs))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addGroup(panelSideProjectLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(labelProjectsDays)
                    .addComponent(projectsDays))
                .addContainerGap(48, Short.MAX_VALUE))
        );

        tabInfoPane.addTab(resourceMap.getString("panelSideProject.TabConstraints.tabTitle"), panelSideProject); // NOI18N

        closeButton.setText(resourceMap.getString("closeButton.text")); // NOI18N
        closeButton.setName("closeButton"); // NOI18N
        closeButton.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                disposeFrame(evt);
            }
        });

        javax.swing.GroupLayout layout = new javax.swing.GroupLayout(getContentPane());
        getContentPane().setLayout(layout);
        layout.setHorizontalGroup(
            layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(layout.createSequentialGroup()
                .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addGroup(layout.createSequentialGroup()
                        .addContainerGap()
                        .addComponent(tabInfoPane, javax.swing.GroupLayout.DEFAULT_SIZE, 451, Short.MAX_VALUE))
                    .addGroup(layout.createSequentialGroup()
                        .addGap(194, 194, 194)
                        .addComponent(closeButton)))
                .addContainerGap())
        );
        layout.setVerticalGroup(
            layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(layout.createSequentialGroup()
                .addComponent(tabInfoPane, javax.swing.GroupLayout.PREFERRED_SIZE, 282, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                .addComponent(closeButton)
                .addContainerGap())
        );

        pack();
    }// </editor-fold>//GEN-END:initComponents

    private void disposeFrame(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_disposeFrame
        Core.calendarTimer.start();
        dispose();
    }//GEN-LAST:event_disposeFrame

    private void showInfo(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_showInfo
        updateGameInfo();
    }//GEN-LAST:event_showInfo

    private void frameDisposed(java.awt.event.WindowEvent evt) {//GEN-FIRST:event_frameDisposed
        Core.calendarTimer.start();
    }//GEN-LAST:event_frameDisposed

    private void viewDevInfo(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_viewDevInfo
        numGames.setText(Integer.toString(Core.devs.get(devList.getSelectedIndex()).getGamesDeveloped()));
        totalExp.setText(Integer.toString(Core.devs.get(devList.getSelectedIndex()).getExperiencePoints()));
        daysWorked.setText(Integer.toString(Core.devs.get(devList.getSelectedIndex()).getDaysWorked()));

    }//GEN-LAST:event_viewDevInfo
    public void updateGameInfo() {

        int selected = listGames.getSelectedIndex();
        if (Core.games.size() > 0) {
            gameName.setText(Core.games.get(selected).getTitle());
            gameGenre.setText(Core.games.get(selected).getGenre());
            gameType.setText(Core.games.get(selected).getType());
            gameFocus.setText(Core.games.get(selected).getFocus());
            gameLanguage.setText(Core.games.get(selected).getLanguage());
            gamePlatform.setText(Core.games.get(selected).getPlatform());
            gameBugs.setText(Integer.toString(Core.games.get(selected).getBugs()));
            gamePrice.setText(Core.nfmt.format(Core.games.get(selected).getPrice()));
            gameLines.setText(Integer.toString(Core.games.get(selected).getTotalLines()));
            int score = Core.games.get(selected).getScore();
            gameScore.setText("" + score);
            System.out.println("" + score );
            statusBar.setValue(Core.games.get(selected).getStatus());
            gameDev.setText(Core.games.get(selected).getDevName());
        }

    }

    /**
     * @param args the command line arguments
     */
    public static void init(String args[]) {
        /* Set the Nimbus look and feel */
        //<editor-fold defaultstate="collapsed" desc=" Look and feel setting code (optional) ">
        /* If Nimbus (introduced in Java SE 6) is not available, stay with the default look and feel.
         * For details see http://download.oracle.com/javase/tutorial/uiswing/lookandfeel/plaf.html 
         */
        try {
            for (javax.swing.UIManager.LookAndFeelInfo info : javax.swing.UIManager.getInstalledLookAndFeels()) {
                if ("Nimbus".equals(info.getName())) {
                    javax.swing.UIManager.setLookAndFeel(info.getClassName());
                    break;
                }
            }
        } catch (ClassNotFoundException ex) {
            java.util.logging.Logger.getLogger(StartupCompanyManager2012CInfo.class.getName()).log(java.util.logging.Level.SEVERE, null, ex);
        } catch (InstantiationException ex) {
            java.util.logging.Logger.getLogger(StartupCompanyManager2012CInfo.class.getName()).log(java.util.logging.Level.SEVERE, null, ex);
        } catch (IllegalAccessException ex) {
            java.util.logging.Logger.getLogger(StartupCompanyManager2012CInfo.class.getName()).log(java.util.logging.Level.SEVERE, null, ex);
        } catch (javax.swing.UnsupportedLookAndFeelException ex) {
            java.util.logging.Logger.getLogger(StartupCompanyManager2012CInfo.class.getName()).log(java.util.logging.Level.SEVERE, null, ex);
        }
        //</editor-fold>

        /* Create and display the form */
        java.awt.EventQueue.invokeLater(new Runnable() {

            public void run() {
                new StartupCompanyManager2012CInfo().setVisible(true);
            }
        });
    }
    // Variables declaration - do not modify//GEN-BEGIN:variables
    private javax.swing.JButton closeButton;
    private javax.swing.JLabel compName;
    private javax.swing.JLabel daysWorked;
    private javax.swing.JList devList;
    private javax.swing.JScrollPane devListScroll;
    private javax.swing.JLabel gameBugs;
    private javax.swing.JLabel gameDev;
    private javax.swing.JLabel gameFocus;
    private javax.swing.JLabel gameGenre;
    private javax.swing.JLabel gameLanguage;
    private javax.swing.JLabel gameLines;
    private javax.swing.JLabel gameName;
    private javax.swing.JLabel gamePlatform;
    private javax.swing.JLabel gamePrice;
    private javax.swing.JLabel gameScore;
    private javax.swing.JLabel gameType;
    private javax.swing.JPanel jPanel1;
    private javax.swing.JPanel jPanel2;
    private javax.swing.JScrollPane jScrollPane1;
    private javax.swing.JLabel labelBudget;
    private javax.swing.JLabel labelBugs;
    private javax.swing.JLabel labelCompanyName;
    private javax.swing.JLabel labelDaysWorked;
    private javax.swing.JLabel labelDevTeam;
    private javax.swing.JLabel labelFocus;
    private javax.swing.JLabel labelGameDev;
    private javax.swing.JLabel labelGameName;
    private javax.swing.JLabel labelGenre;
    private javax.swing.JLabel labelLanguage;
    private javax.swing.JLabel labelLines;
    private javax.swing.JLabel labelMainDev;
    private javax.swing.JLabel labelPlatform;
    private javax.swing.JLabel labelPrice;
    private javax.swing.JLabel labelProjectBonus;
    private javax.swing.JLabel labelProjectEarnings;
    private javax.swing.JLabel labelProjectMoneyLost;
    private javax.swing.JLabel labelProjectsBugs;
    private javax.swing.JLabel labelProjectsCount;
    private javax.swing.JLabel labelProjectsDays;
    private javax.swing.JLabel labelProjectsFailed;
    private javax.swing.JLabel labelProjectsFinished;
    private javax.swing.JLabel labelProjectsLines;
    private javax.swing.JLabel labelScore;
    private javax.swing.JLabel labelStatus;
    private javax.swing.JLabel labelTeamSize;
    private javax.swing.JLabel labelTotalExp;
    private javax.swing.JLabel lableNumGames;
    private javax.swing.JLabel lableType;
    private javax.swing.JList listGames;
    private javax.swing.JLabel liveBudget;
    private javax.swing.JLabel mainDevName;
    public javax.swing.JLabel numGames;
    private javax.swing.JPanel panelFinancial;
    private javax.swing.JPanel panelGames;
    private javax.swing.JPanel panelGeneral;
    private javax.swing.JPanel panelSideProject;
    private javax.swing.JLabel projectsBonus;
    private javax.swing.JLabel projectsCount;
    private javax.swing.JLabel projectsDays;
    private javax.swing.JLabel projectsEarnings;
    private javax.swing.JLabel projectsFailed;
    private javax.swing.JLabel projectsFinished;
    private javax.swing.JLabel projectsLines;
    private javax.swing.JLabel projectsMoneyLost;
    private javax.swing.JLabel projectsTotalBugs;
    private javax.swing.JProgressBar statusBar;
    private javax.swing.JTabbedPane tabInfoPane;
    private javax.swing.JLabel teamSize;
    private javax.swing.JLabel totalExp;
    // End of variables declaration//GEN-END:variables
}
